package com.dayuanit.dy17.mix.aop.aspect;

import org.aspectj.lang.ProceedingJoinPoint;
import org.aspectj.lang.annotation.Around;
import org.aspectj.lang.annotation.Aspect;
import org.aspectj.lang.annotation.Pointcut;
import org.springframework.stereotype.Component;

@Component
@Aspect
public class FomartAspect {

    @Pointcut("execution(* com.dayuanit.dy17.mix.aop.service.impl.UserServiceImpl.login(..))")
    public void pointCut() {

    }

    @Around("pointCut()")
    public void around(ProceedingJoinPoint joinPoint) {
        try {
//            joinPoint.proceed();
            joinPoint.proceed(new Object[]{"steve", "123456"});
        } catch (Throwable throwable) {
            throwable.printStackTrace();
        }
    }
}
